package com.youkeyi.ddy.cloud.common.api.application.business.crm.order;

import com.youkeyi.ddy.cloud.common.api.application.business.crm.order.dto.BusinessCustomerVaccineOrderListCloudDto;
import com.youkeyi.ddy.cloud.common.api.application.business.crm.order.dto.BusinessCustomerVaccineOrderRecipientDetailsCloudDto;
import com.youkeyi.ddy.cloud.common.api.application.business.crm.order.param.*;
import com.youkeyi.ddy.cloud.common.response.ResponseContent;
import io.swagger.annotations.*;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

/**
 * 系统客户疫苗订单
 *
 * @author  liuxiawang
 * @Date 5/24/22 10:36 PM
 * @Location shenzhen.china
 */
@Api(tags = {"【BUSINESS】Vaccine Order Management"})
@RestController
@FeignClient(value = "YOUKEYI-DDY-CLOUD-APPLICATION-BUSINESS", fallback = BusinessCustomerVaccineOrderCloudServiceFallback.class)
@RequestMapping("/business/customer/vaccine/order")
public interface BusinessCustomerVaccineOrderCloudService {

    // 查询客户疫苗订单列表
    @ApiOperation(value = "Query Business Customer Vaccine Order List", authorizations = {@Authorization("com.youkeyi.ddy.cloud.common.api.application.business.crm.order.BusinessCustomerVaccineOrderCloudService.list")})
    @ApiResponse(code = 200, message = "data Property in Response Body", response = BusinessCustomerVaccineOrderListCloudDto.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "param", paramType = "query", value = "Param of Query Business Customer Vaccine Order List", dataType = "BusinessCustomerVaccineOrderListCloudParam", dataTypeClass = BusinessCustomerVaccineOrderListCloudParam.class),
    })
    @GetMapping
    public abstract BusinessCustomerVaccineOrderListCloudDto list(BusinessCustomerVaccineOrderListCloudParam param);


    // 创建客户疫苗订单
    @ApiOperation(value = "Create Business Customer Vaccine Order", authorizations = {@Authorization("com.youkeyi.ddy.cloud.common.api.application.business.crm.order.BusinessCustomerVaccineOrderCloudService.create")})
    @ApiResponse(code = 200, message = "data Property in Response Body", response = ResponseContent.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "param", paramType = "body", value = "Param of Create Business Customer Vaccine Order", dataType = "BusinessCustomerVaccineOrderCreateCloudParam", dataTypeClass = BusinessCustomerVaccineOrderCreateCloudParam.class),
    })
    @PostMapping("/create")
    public abstract ResponseContent create(@RequestBody BusinessCustomerVaccineOrderCreateCloudParam param);


    // 编辑客户疫苗订单
    @ApiOperation(value = "Update Business Customer Vaccine Order", authorizations = {@Authorization("com.youkeyi.ddy.cloud.common.api.application.business.crm.order.BusinessCustomerVaccineOrderCloudService.update")})
    @ApiResponse(code = 200, message = "data Property in Response Body", response = ResponseContent.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "param", paramType = "body", value = "Param of Update Business Customer Vaccine Order", dataType = "BusinessCustomerVaccineOrderUpdateCloudParam", dataTypeClass = BusinessCustomerVaccineOrderUpdateCloudParam.class),
    })
    @PatchMapping("update")
    public abstract ResponseContent update(@RequestBody BusinessCustomerVaccineOrderUpdateCloudParam param);


    // 删除客户疫苗订单
    @ApiOperation(value = "Delete Business Customer Vaccine Order", authorizations = {@Authorization("com.youkeyi.ddy.cloud.common.api.application.business.crm.order.BusinessCustomerVaccineOrderCloudService.delete")})
    @ApiResponse(code = 200, message = "data Property in Response Body", response = ResponseContent.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "param", paramType = "query", value = "Param of Delete Business Customer Vaccine Order", dataType = "BusinessCustomerVaccineOrderDeleteCloudParam", dataTypeClass = BusinessCustomerVaccineOrderDeleteCloudParam.class),
    })
    @DeleteMapping("/delete")
    public abstract ResponseContent delete(BusinessCustomerVaccineOrderDeleteCloudParam param);



    // 查询客户疫苗详情
    @ApiOperation(value = "Query Customer Vaccine Order Recipient Details", authorizations = {@Authorization("com.youkeyi.ddy.cloud.common.api.application.business.crm.order.BusinessCustomerVaccineOrderCloudService.recipientDetails")})
    @ApiResponse(code = 200, message = "data Property in Response Body", response = BusinessCustomerVaccineOrderRecipientDetailsCloudDto.class)
    @ApiImplicitParams({
            @ApiImplicitParam(name = "param", paramType = "query", value = "Param of Query Customer Vaccine Order Recipient Details", dataType = "BusinessCustomerVaccineOrderRecipientDetailsCloudParam", dataTypeClass = BusinessCustomerVaccineOrderRecipientDetailsCloudParam.class),
    })
    @GetMapping("/recipient/details")
    public abstract BusinessCustomerVaccineOrderRecipientDetailsCloudDto recipientDetails(BusinessCustomerVaccineOrderRecipientDetailsCloudParam param);

}
